#ifndef BEDITOR_H
#define BEDITOR_H

#include "Qsci/qsciscintilla.h"
#include <QMainWindow>

QT_BEGIN_NAMESPACE
namespace Ui { class Beditor; }
QT_END_NAMESPACE

class Beditor : public QMainWindow
{
    Q_OBJECT

public:
    Beditor(QWidget *parent = nullptr);
    void closeEvent(QCloseEvent *event);
    ~Beditor();

public slots:
    void runCode();
    void openFile();
    void saveFile();
    void saveAsFile();
    void newFile();
    void showAbout();

private:
    void Init_Editor();
    void Init_ShortCut();

    Ui::Beditor *ui;
    QsciScintilla *editor;
    QString currentFile;
    QString savePath;
    bool tempFile;
    bool unsave;
};
#endif // BEDITOR_H
